<?php
class permissionsApp extends core
{
    public function addPermissions($arg)
    {
		if (base::init('permissions')->insert($arg))
        {
			$this->refresh('添加成功',"index.php?m=permissions&a=permissionsList");
        }
    }

    public function permissionsList()
    {
        return base::init('permissions')->permissionsList();
    }

    public function groupList()
    {
        $result = base::init('permissions')->groupList();
        return $result;
    }

    public function isPermission($uid, $permission)
    {
        $result = base::init('permissions')->isPermission($uid, $permission);
        return $result;
    }
}
